package day04;
import java.util.Scanner;
public class TaskThree {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int numb = (int)(Math.random()*1000+1);
        int guess;
        do {
            System.out.println("猜数字开始啦!请输入数字呦");
            guess = scan.nextInt();
            if (guess>numb){
                System.out.println("猜大了呦");
            }else if (guess<numb){
                System.out.println("猜小了呦");
            }else{
                System.out.println("恭喜你猜对了");
            }

        }while (guess!=numb);
    }
}
